# Maintainer: Felix Yan <felixonmars@archlinux.org>
# Contributor: Daniel Wallace <danielwallace at gtmanfred dot com>

pkgname=python-openstackclient
pkgver=6.3.0
_commit=08faf81d0d81153d0b11d155a2162f00c039cb3f
pkgrel=1
pkgdesc="OpenStack Command-line Client"
arch=('any')
url="https://docs.openstack.org/python-openstackclient/latest/"
license=('Apache')
depends=('python-pbr' 'python-cryptography' 'python-cliff' 'python-iso8601' 'python-openstacksdk'
         'python-osc-lib' 'python-oslo-i18n' 'python-oslo-utils' 'python-keystoneclient'
         'python-novaclient' 'python-cinderclient' 'python-stevedore')
makedepends=('git')
checkdepends=('python-oslotest' 'python-requests' 'python-requests-mock' 'python-stestr'
              'python-testtools' 'python-wrapt' 'python-ddt')
source=("git+https://github.com/openstack/python-openstackclient.git#commit=$_commit")
sha512sums=('SKIP')

build() {
  cd python-openstackclient
  python setup.py build
}

check() {
  cd python-openstackclient
  stestr run
}

package() {
  cd python-openstackclient
  python setup.py install --root="$pkgdir" --optimize=1
}
